﻿using System;

namespace BSharp.Compiler.Emit
{
	public class DefineLabel : IntermediateInstruction
	{
		public readonly Symbol Symbol;

		public DefineLabel (Symbol sym)
		{
			Symbol = sym;
		}

		public override void Visit (IntermediateCompiler compiler)
		{
			compiler.Compile (this);
		}

		public override string ToString ()
		{
			return String.Format ("{0}:", Symbol.Name);
		}
	}
}

